{% extends "desk/desk_base.html" %}
{% block title %}
    修改桌子
{% endblock %}
{% block content %}
    <ol class="breadcrumb">
      <li><a href="#">首页</a></li>
      <li><a href="#">桌子管理</a></li>
      <li class="active">修改桌子信息</li>
    </ol>

    <form action="{{ url_for("desk.update_desk") }}" method="POST">
        <table width="0">
        <tr>
            <td>
                <div class="input-group">
                    <span class="input-group-addon" id="basic-addon3">桌子名</span>
                    <input type="text" class="form-control" id="basic-url" name="desk_name" aria-describedby="basic-addon3">
                </div>
            </td>
            <td>
                <button class="btn btn-primary" type="submit">查找</button>
            </td>
        </tr>
    </table>
    </form>
    <table class="table">
        <tr>
            <td>序号</td>
            <td>桌子名</td>
            <td>操作</td>
        </tr>
    {% for desk in desks %}
        <tr>
            <td>{{ loop.index }}</td>
            <td>{{ desk.desk_name }}</td>
            <td><a href="{{url_for("desk.update_desk_info",desk_no=desk.desk_no)}}" class="btn btn-warning btn-sm" role="button">修改</a></td>
        </tr>
    {% endfor %}
    </table>
    <ul>
     {% for error in get_flashed_messages() %}
        <li class="text-danger">{{ error }}</li>
     {% endfor %}
    </ul>

{% endblock %}